﻿<%@ Register TagPrefix="ucCommon" TagName="Common" Src="../Common/Inc/Common.ascx" %>
<%@ Register TagPrefix="ucTabTitle" TagName="TabTitle" Src="../Common/Inc/TabTitle.ascx" %>
<%@ Register TagPrefix="ucCopyright" TagName="Copyright" Src="../Common/Inc/Copyright.ascx" %>
<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Mny3012p.aspx.cs" Inherits="Updms.Mny.Mny3012p" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" >
<head runat="server">
<title>▒ UPDMS [Mny3012p] ▒▒▒▒▒▒▒▒▒▒</title>
<ucCommon:Common id="Common" runat="server"></ucCommon:Common>
</head>
<body>
<form id="form1" runat="server">
<asp:ScriptManager runat="server" id="ScriptManager1" EnableScriptGlobalization="true"></asp:ScriptManager>

<table id="table_frame">
	<tr>
		<td id="contents_area">
			<!-- 제목 시작 -->
			<ucTabTitle:TabTitle id="TabTitle" TagPrefixs="Mny3012p" runat="server"></ucTabTitle:TabTitle>
			<!-- 제목 끝 -->
			<!-- AJAX 시작 -->
			<asp:UpdatePanel ID="UpdatePanel1" runat="server">
			<ContentTemplate>
			<!-- 버튼 시작 -->
			<div class="button_area">
				<asp:linkbutton id="ibtn_close" Text="닫기" runat="server" CssClass="ibtn ibtn_close" OnClientClick="javascript:window.close();return false;"></asp:linkbutton>
				<asp:linkbutton id="ibtn_save" Text="저장" runat="server" CssClass="ibtn ibtn_save" OnClientClick="return chkSave()" OnClick="ibtn_save_Click"></asp:linkbutton>
			</div>
			<!-- 버튼 끝 -->
			<!-- 리스트셋 시작 -->
			<table id="table_list_set" cellspacing="0" cellpadding="0" width="100%" border="0">
				<tr>
					<td>
						<!-- 리스트 시작 -->
						<asp:GridView ID="GridView1" CssClass="table_gridview" GridLines="None" runat="server" AutoGenerateColumns="False" OnRowDataBound="GridView1_RowDataBound" DataKeyNames="Seq" ShowFooter="True">
							<Columns>
								<asp:TemplateField HeaderText="S">
									<ItemTemplate>
										<asp:CheckBox ID="cb_check" runat="server" Checked="true" AutoPostBack="True" OnCheckedChanged="cb_check_CheckedChanged" />
									</ItemTemplate>
									<ItemStyle HorizontalAlign="Center" Width="2%" />
								</asp:TemplateField>
								<asp:BoundField HeaderText="번호" >
									<ItemStyle HorizontalAlign="Center" Width="6%" />
								</asp:BoundField>
								<asp:BoundField DataField="Seq" HeaderText="Seq(X)" Visible="False" />
								<asp:BoundField DataField="Reg_Dt" HeaderText="등록일" HtmlEncode="False" >
									<ItemStyle HorizontalAlign="Center" Width="10%" />
								</asp:BoundField>
								<asp:BoundField DataField="Account_Nm" HeaderText="계정" HtmlEncode="False" >
									<ItemStyle HorizontalAlign="Left" Width="15%" />
								</asp:BoundField>
								<asp:BoundField DataField="Contents" HeaderText="내용" HtmlEncode="False" >
									<ItemStyle HorizontalAlign="Left" Width="23%" />
								</asp:BoundField>
								<asp:BoundField DataField="Amount" HeaderText="금액" DataFormatString="{0:#,##0}" HtmlEncode="False" >
									<ItemStyle HorizontalAlign="Right" Width="14%" />
								</asp:BoundField>
								<asp:BoundField DataField="Remark" HeaderText="비고" HtmlEncode="False" >
									<ItemStyle HorizontalAlign="Left" Width="30%" />
								</asp:BoundField>
							</Columns>
							<EmptyDataTemplate>
								<div id="no_data"></div>
							</EmptyDataTemplate>
						</asp:GridView>
						<!-- 리스트 끝 -->
					</td>
				</tr>
			</table>
			<!-- 리스트셋 끝 -->
			<!-- 디테일1 시작 -->
			<br />
			<div class="sub_title_icon"><asp:Literal id="ltr_stitle_living_cost_balance" Text="차감할 생활비" runat="server" /></div>
			<table class="table_detail">
				<tr>
					<td class="lbl" width="22%"><asp:Literal id="ltr_living_cost" Text="생활비" runat="server" /></td>
					<td class="ctl" width="78%"><asp:DropDownList ID="ddl_living_cost" CssClass="ddl" runat="server"></asp:DropDownList></td>
				</tr>
			</table>
			<!-- 디테일1 끝 -->
			<!-- 카피라이트 시작 -->
			<ucCopyright:Copyright id="Copyright" runat="server"></ucCopyright:Copyright>
			<!-- 카피라이트 끝 -->
			<!-- 히든값 시작 -->
			<div id="hdn_data">
				<asp:label id="lbl_pk" runat="server"></asp:label>
			</div>
			<!-- 히든값 끝 -->
			</ContentTemplate>
			</asp:UpdatePanel>
			<!-- AJAX 끝 -->
		</td>
	</tr>
</table>

<asp:updateprogress AssociatedUpdatePanelID="UpdatePanel1" ID="updateProgress" runat="server">
	<progresstemplate>
		<div id="progressBackgroundFilter"></div>
		<div id="processMessage">
			<div id="processing"></div>
			<img src="../Common/Images/processing_img.gif" />
		</div>
	</progresstemplate>
</asp:updateprogress>

</form>
<script type="text/javascript" language="javascript" defer="defer">
	//저장
	function chkSave() {
		if ($F("ddl_living_cost") == null || $F("ddl_living_cost").blank()) {
			msgBox.alert(getMsg(MSG_ERR_189)); //등록된 생활비가 없습니다
			return false;
		}

		msgBox.confirm(getMsg(MSG_CFM_019), doSave); //차감하시겠습니까?
		return false;
	}

</script>
</body>
</html>